package com.xmb.wcapi.service.impl;

import java.util.List;

import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.xmb.wcapi.entity.SysMenu;
import com.xmb.wcapi.mapper.SysMenuMapper;
import com.xmb.wcapi.service.ISysMenuService;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author huangping
 * @since 2020-03-04
 */
@Service
public class SysMenuServiceImpl extends ServiceImpl<SysMenuMapper, SysMenu> implements ISysMenuService {

	@Override
	public List<SysMenu> selectInfoList(Wrapper<SysMenu> ew) {
		return list(ew);
	}

	@Override
	public long selectInfoCount(Wrapper<SysMenu> ew) {
		return count(ew);
	}

	@Override
	public void addInfo(SysMenu sysMenu) throws Exception{
		save(sysMenu);
	}

	@Override
	public SysMenu selectInfo(Wrapper<SysMenu> ew) {
		return getOne(ew);
	}

	@Override
	public void edit(SysMenu sysMenu) throws Exception{
		updateById(sysMenu);
	}
}
